#include "Agua.h"
#include "StageParser.h"
#include "Stage.h""

Agua::Agua() {
	Stage stage = StageParser::getInstance()->getGameStageData();
	this->nivelLogica = stage.getWaterLevel();
	unsigned int altoPantallaLogica = stage.getLUWindowHigh();
	unsigned int altoPantallaPixel = stage.getPxWindowHigh();
	float escala = (float)altoPantallaPixel / (float)altoPantallaLogica;
	this->nivelPixel = nivelLogica * escala;
}

Agua::Agua(unsigned int nivelPixel, unsigned int nivelLogica) {
	this->nivelPixel = nivelPixel;
	this->nivelLogica = nivelLogica;
}

Agua::Agua(unsigned int nivelLogica, unsigned int altoPantallaLogica,
		unsigned int altoPantallaPixel) {
	float escala = altoPantallaPixel / altoPantallaLogica;
	this->nivelLogica = nivelLogica;
	this->nivelPixel = nivelLogica * escala;
}

Agua::~Agua() {
}

unsigned int Agua::getNivelPixel() {
	return nivelPixel;
}
unsigned int Agua::getNivelLogica() {
	return nivelLogica;
}
